package com.bw.lib_core.mvp.presenter;

import com.bw.lib_core.mvp.model.IModel;
import com.bw.lib_core.mvp.view.IView;

public class BasePresenter<M extends IModel,V extends IView> implements IPresenter {
    protected  M Mmodel;
    protected  V Vview;

    public BasePresenter(M mmodel, V vview) {
        Mmodel = mmodel;
        Vview = vview;
    }

    @Override
    public void destory() {
        if (Mmodel!=null){
            Mmodel.destory();
            Mmodel=null;
        }
        if (Vview!=null){
            Vview=null;
        }
    }
}
